export const ERROR = {
  TOKEN_EXPIRED: 'uni-id-token-expired',
  CHECK_TOKEN_FAILED: 'uni-id-check-token-failed',
  PARAM_REQUIRED: 'uni-id-param-required',
  ACCOUNT_EXISTS: 'uni-id-account-exists',
  ACCOUNT_NOT_EXISTS: 'uni-id-account-not-exists',
  ACCOUNT_CONFLICT: 'uni-id-account-conflict',
  ACCOUNT_BANNED: 'uni-id-account-banned',
  ACCOUNT_AUDITING: 'uni-id-account-auditing',
  ACCOUNT_AUDIT_FAILED: 'uni-id-account-audit-failed',
  ACCOUNT_CLOSED: 'uni-id-account-closed'
}

export function isUniIDError (errCode) {
  return Object.values(ERROR).includes(errCode)
}
